//
//  FinancialInfoCell.m
//  BaseFrame
//
//  Created by wingfac on 2017/8/11.
//  Copyright © 2017年 com.mxh. All rights reserved.
//

#import "FinancialInfoCell.h"
@interface FinancialInfoCell ()
@property (nonatomic,strong)UILabel *title;
@property (nonatomic,strong)UILabel *content;
@property (nonatomic,strong)UIView *bgView;
@end
@implementation FinancialInfoCell

-(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if(self){
        self.selectionStyle = UITableViewCellSelectionStyleNone;
        self.backgroundColor = getColor(@"ebebf1");
        _bgView = [[UIView alloc] initWithFrame:CGRectMake(5/WIDTH_5S_SCALE, 0, SCREEN_WIDTH-10/WIDTH_5S_SCALE, 40/WIDTH_5S_SCALE)];
        _bgView.backgroundColor = [UIColor whiteColor];
        [self.contentView addSubview:self.bgView];
        
        _title = [[UILabel alloc] initWithFrame:CGRectMake(5, 0, 100/WIDTH_5S_SCALE, _bgView.frame.size.height)];
        _title.font = DEF_FontSize_14;
        _title.textAlignment = NSTextAlignmentLeft;
        [self.bgView addSubview:self.title];
        
        _content = [[UILabel alloc] initWithFrame:CGRectMake(CGRectGetMaxX(_title.frame), 0, _bgView.frame.size.width - 110/WIDTH_5S_SCALE, _bgView.frame.size.height)];
        _content.font = DEF_FontSize_14;
        _content.textAlignment = NSTextAlignmentRight;
        [self.bgView addSubview:self.content];
        
    }
    return self;
}
- (void) setTitle:(NSString *)title content:(NSString *)content textColor:(UIColor *)color{
    _title.text = title;
    _content.text = content;
    _title.textColor = color;
    _content.textColor = color;
}
@end
